{% extends 'base.html' %}

{% block title %}年级日程详情{% endblock %}

{% block content %}
<div class="container mt-4">
    <div class="row">
        <div class="col-md-8 offset-md-2">
            <h1 class="mb-4">年级日程详情</h1>
            <div class="card">
                <div class="card-body">
                    <h5 class="card-title">ID: {{ schedule.id }}</h5>
                    <p class="card-text"><strong>年级:</strong> {{ schedule.grade.name }}</p>
                    <p class="card-text"><strong>学期:</strong> {{ schedule.semester.name }}</p>
                    <p class="card-text"><strong>日期:</strong> {{ schedule.date }}</p>
                    <p class="card-text"><strong>星期:</strong> {{ schedule.get_weekday }}</p>
                    <p class="card-text"><strong>是否上课:</strong> {{ schedule.get_is_class_day_display }}</p>
                    <p class="card-text"><strong>创建时间:</strong> {{ schedule.created_at }}</p>
                </div>
                <div class="card-footer">
                    <a href="{% url 'core:grade_schedule_update' schedule.id %}" class="btn btn-warning">编辑</a>
                    <a href="{% url 'core:grade_schedule_delete' schedule.id %}" class="btn btn-danger">删除</a>
                    <a href="{% url 'core:grade_schedule_list' %}" class="btn btn-secondary">返回列表</a>
                </div>
            </div>
        </div>
    </div>
</div>
{% endblock %}